<?php

include_once 'index.php';

$redis = CacheRedis::getInstance();
$key = Consts::KEY_NEWS_TYPE;

$arr = [
    '国内',
    '国际',
    '军事',
    '社会',
    '财经',
    '娱乐',
    '体育',
    '互联网',
    '科技',
    '游戏',
    '房产',
    '汽车'
];

//$redis->hMset($key, $arr);

foreach($arr as $index => $name)
{
    $redis->hSet($key, $index + 1, $name);
}
